_ostree_sysroot_write_deployments_internal: stop leaking hash table
authorSimon McVittie <smcv@debian.org>
Sat, 29 Oct 2016 17:37:09 +0000 (18:37 +0100)
committerAtomic Bot <atomic-devel@projectatomic.io>
Sun, 30 Oct 2016 22:11:15 +0000 (22:11 +0000)
It appears the result of assign_bootserials() is never actually used,
but I haven't changed it to return void right now.

Leak found with valgrind memcheck.

Signed-off-by: Simon McVittie <smcv@debian.org>
Closes: #556
Approved by: cgwalters

src/libostree/ostree-sysroot-deploy.c

index 427e188bb0daab06dd96256f7661d9c705ae9bda..cb5a46156a4118066ef4a8f4168483d87364b0ee 100644 (file)
@@ -1747,7 +1747,7 @@ _ostree_sysroot_write_deployments_internal (OstreeSysroot     *self,
 
   /* Assign a bootserial to each new deployment.
    */
-  assign_bootserials (new_deployments);
+  g_hash_table_unref (assign_bootserials (new_deployments));
 
   /* Determine whether or not we need to touch the bootloader
    * configuration.  If we have an equal number of deployments with